Ext.namespace("Project.Main");

Project.Main.tabIndex = {
	"taken" : 0,
	"unfinished": 1
};

Project.Main.panel = function(taskType) {
	var opentab = Utils.getParameter('opentab');
	if (!opentab) opentab = "taken";
	
	this.tabPanel = new Ext.TabPanel({
		region:'center',
		activeTab: Project.Main.tabIndex[opentab]
	});
	if(!Project.Prepare.panel.instance)
		Project.Prepare.panel.instance = new Project.Prepare.panel();
	this.tabPanel.add(Project.Prepare.panel.instance);
	Project.Main.panel.superclass.constructor.call(this, {
		layout:'border',
		items:[this.tabPanel],
		listeners:{
		}
	});
};
Ext.extend(Project.Main.panel, Ext.Viewport, {

});

Ext.onReady(function() {
    Ext.QuickTips.init();
    Ext.form.Field.prototype.msgTarget = 'side';
    Ext.BLANK_IMAGE_URL = '../resources/images/default/s.gif';
    new Project.Main.panel();
   
});

